/*
 * =====================================================================================
 *
 *       Filename:  1-sort.h
 *
 *    Description:  
 *
 *        Version:  1.0
 *        Created:  2011-11-9 16:36:34
 *       Revision:  none
 *       Compiler:  gcc
 *
 *         Author:  YOUR NAME (), 
 *        Company:  
 *
 * =====================================================================================
 */
#ifndef _1_SORT_H_
#define _1_SORT_H_

#define MAX_INT 10000000

int bit(char A[], int k)
{
    return (A[k >> 3] >> (k % 8)) & 0x01;
}

void set_bit(char A[], int k)
{
    A[k >> 3] = A[k >> 3] | (0x01 << (k % 8));
}

void clr_bit(char A[], int k) {
    A[k >> 3] = A[k >> 3] & (~(0x01 << (k % 8)));

}
#endif
